﻿<%@ Page Language="C#" AutoEventWireup="true"  CodeBehind="PrintEmergency.aspx.cs" Inherits="lcs.Web.Outstorage.PrintEmergency" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
    <title></title>
    <style type="text/css">
        .aline_center
        {
            margin-left: auto;
            margin-right: auto;
            overflow: hidden;
        }
        body
        {
            font-size: 10pt;
        }
    </style>
    <script language="javascript" type="text/javascript">

        function printpage(myDiv) {

            //var newstr = document.all.item(myDiv).innerHTML; 
            var newstr = document.getElementById(myDiv).innerHTML;
            //alert(newstr);
            var oldstr = document.body.innerHTML;
            document.body.innerHTML = newstr;
            window.print();
            document.body.innerHTML = oldstr;
            return false;
        } 
    </script>
    <%
        Response.Buffer = true;
        Response.ExpiresAbsolute = System.DateTime.Now.AddSeconds(-1);
        Response.Expires = 0;
        Response.CacheControl = "no-cache";
    %>
</head>
<body>
    <form id="form1" runat="server">
    <div class="aline_center" style="text-align: center">
        <div id='myDiv'>
            <div class="aline_center" style=" text-align:center;font-size: 40px; font-weight: bold; font-family: 黑体">
                应 急
                出 库 单</div>
            <div style="margin: 10px;">
                <table class="aline_center" style="width: 17cm;">
                    <tr>
                        <td style="text-align: left; height: 20px;" colspan="2">
                            <b>应急出库单编号：</b><asp:Label ID="lbl_batchId" runat="server"></asp:Label>
                            
                        </td>
                    </tr>
                    <tr>
                        <td style="text-align: left; height: 20px;" colspan="2">
                            <b>项目名称</b>：<asp:Label ID="lbl_project_name" runat="server" Text=""></asp:Label>
                            ，<b>项目编号</b>：<asp:Label ID="lbl_proid" runat="server" Text=""></asp:Label>
                        </td>
                    </tr>
                    <tr>
                        <td style="text-align: left; height: 20px;" colspan="2">
                            <b>到货地点</b>：<asp:Label ID="lbl_receive_address" runat="server"></asp:Label>
                        </td>
                    </tr>
                    <tr>
                        <td style="text-align: left; height: 20px;" colspan="2">
                            <b>接收人</b>：<asp:Label ID="lbl_receive_userName" runat="server"></asp:Label>
                            ，<b>接收人电话</b>：<asp:Label ID="lbl_receive_userPhone" runat="server"></asp:Label>
                        </td>
                    </tr>
                    <tr>
                        <td style="text-align: left; font-weight: bold; height: 20px;" colspan="2">
                            &nbsp;
                        </td>
                    </tr>
                    <tr>
                        <td style="text-align: left; height: 20px; text-align: center" colspan="2">
                            <asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False" Width="100%">
                                <Columns>
                                    <asp:BoundField HeaderText="物料描述" DataField="material" />
                                    <asp:BoundField HeaderText="数量" DataField="emergencyNums"  DataFormatString="{0:0.00}"/>
                                    <asp:BoundField HeaderText="单位" DataField="unit" />
                                    <asp:BoundField HeaderText="应急出库时间" DataField="emergencyTime" />
                                </Columns>
                                <RowStyle Height="20px" />
                            </asp:GridView>
                        </td>
                    </tr>
                    <tr>
                        <td style="text-align: left; font-weight: bold; height: 20px;" colspan="2">
                        </td>
                    </tr>
                    <tr>
                        <td style="text-align: left; font-weight: bold; height: 50px; width: 200px;">
                            物流领料人签字：
                        </td>
                        <td style="text-align: left; font-weight: bold; height: 50px; width: 200px;">
                            收货人签字：
                        </td>
                    </tr>
                </table>
            </div>
        </div>
        <div>
            <input type="button" id="bt" onclick="javascript:printpage('myDiv')" value=" 打  印 " />
        </div>
    </div>
    </form>
</body>
</html>